#!/bin/bash

export PATH=$PATH:$PWD/test-hooks/bin
export PYTHONPATH=$PWD/test-hooks/py/272eeaf7a23c

socat -d -d pty,rawer,echo=0 pty,rawer,echo=0 &

BUILD_DIR=/home/maliuping/workspace/test/test_0210/output/lq1000_qemu_defconfig/uboot
RESULT_DIR=/home/maliuping/workspace/test/test_0210/uboot-test-res
DATA_DIR=/home/maliuping/workspace/test/test_0210/uboot-test-res

TOOL_DIR=$PWD/py/

python3 $TOOL_DIR/test.py --bd lq1000 --build-dir $BUILD_DIR --result-dir $RESULT_DIR --persistent-data-dir $DATA_DIR

ps aux | grep socat | grep -v grep | awk '{print $2}' | xargs kill
